package sk.uniza.fri.cerviix.client.network.message.client;

import java.io.IOException;

import sk.uniza.fri.cerviix.client.network.ClientMessage;
import sk.uniza.fri.cerviix.client.network.MessageType;

public class ConnectMessage extends ClientMessage
{
	private String playerName;
	
	public ConnectMessage(String playerName)
	{
		this.playerName = playerName;
	}
	
	@Override
	public void send() throws IOException
	{
		setHeader(MessageType.CONNECT);
		
		stream.writeUTF(playerName);
	}
}
